import { HIDEMODAL, SHOWMODAL } from '../const/modal.const'
const initlialState = {
	show: false,
}

export default (state = initlialState, action) => {
	let { type } = action
	switch (type) {
		case SHOWMODAL:
			return {
				...state,
				show: true,
			}
		case HIDEMODAL:
			return {
				...state,
				show: false,
			}
		default:
			return state
	}
}
